cargo.git
9 years agoAuto merge of #3426 - nrc:check-fix-2, r=alexcrichton
bors [Mon, 26 Dec 2016 03:52:05 +0000 (03:52 +0000)]
Auto merge of #3426 - nrc:check-fix-2, r=alexcrichton

Test for #3419

Based on top of https://github.com/rust-lang/cargo/pull/3425.

I'm not sure if this is an acceptable test because it downloads rustc-serialize.

r? @alexcrichton

9 years agoAuto merge of #3436 - matklad:abs-target, r=alexcrichton
bors [Mon, 26 Dec 2016 02:45:07 +0000 (02:45 +0000)]
Auto merge of #3436 - matklad:abs-target, r=alexcrichton

Make sure targets always use absolute path

Closes #3416

I'd want to add a test for it later. Seems a bit suspicious that this change has not caused any test to fail.

9 years agoAuto merge of #3457 - alexcrichton:no-check-on-beta, r=alexcrichton
bors [Sun, 25 Dec 2016 23:53:35 +0000 (23:53 +0000)]
Auto merge of #3457 - alexcrichton:no-check-on-beta, r=alexcrichton

Only run check tests on nightly

9 years agoOnly run check tests on nightly
Alex Crichton [Sun, 25 Dec 2016 22:01:03 +0000 (14:01 -0800)]
Only run check tests on nightly

9 years agoTest for cargo check with macro and both lib and bin.
Nick Cameron [Sun, 18 Dec 2016 21:52:50 +0000 (10:52 +1300)]
Test for cargo check with macro and both lib and bin.

Closes #3419

9 years agoAdd a test
Nick Cameron [Sat, 17 Dec 2016 20:23:33 +0000 (10:23 -1000)]
Add a test

Includes adding facility for checking that output does not contain a string.

9 years agoMake sure targets always use absolute path
Aleksey Kladov [Wed, 21 Dec 2016 06:22:00 +0000 (09:22 +0300)]
Make sure targets always use absolute path

9 years agoAuto merge of #3430 - alexcrichton:bump, r=brson
bors [Tue, 20 Dec 2016 00:32:58 +0000 (00:32 +0000)]
Auto merge of #3430 - alexcrichton:bump, r=brson

Bump to 0.17.0

9 years agoBump to 0.17.0
Alex Crichton [Tue, 20 Dec 2016 00:28:47 +0000 (16:28 -0800)]
Bump to 0.17.0

9 years agoAuto merge of #3424 - matklad:naming-things, r=alexcrichton
bors [Mon, 19 Dec 2016 19:54:03 +0000 (19:54 +0000)]
Auto merge of #3424 - matklad:naming-things, r=alexcrichton

Minor, more explicit names

Ultraminor renaming. Have to look at this tests because it fails if you link with older libgit.

9 years agoAuto merge of #3413 - matklad:ref, r=alexcrichton
bors [Mon, 19 Dec 2016 18:19:00 +0000 (18:19 +0000)]
Auto merge of #3413 - matklad:ref, r=alexcrichton

Refactor resolve_dependencies

This moves `resolve_dependencies` function from `compile.rs` into the `resolve.rs`, where it more reasonably belongs.

9 years agoAuto merge of #3410 - fmdkdd:fix-3390-message-format-parse-stderr, r=alexcrichton
bors [Mon, 19 Dec 2016 17:04:04 +0000 (17:04 +0000)]
Auto merge of #3410 - fmdkdd:fix-3390-message-format-parse-stderr, r=alexcrichton

Fix `--message-format JSON` when rustc emits non-JSON warnings

The `--message-format JSON` flag parses all the stderr output of rustc to JSON,
but rustc can emit non-JSON lines to stderr (e.g., for warning about the
unstable `-Z` flag on the stable channel), causing cargo to fail reporting
compilation errors when using `--message-format JSON`.

This commit adds a check to look for lines beginning with `{` to only parse
these lines as JSON.  Other lines from rustc are forwarded to the stderr of
cargo.

Fixes #3390.

9 years agomake sure we use the check profile where possible for lib deps.
Nick Cameron [Sat, 17 Dec 2016 19:08:14 +0000 (09:08 -1000)]
make sure we use the check profile where possible for lib deps.

Fixes #3418

9 years agoMinor, more explicit names
Aleksey Kladov [Sun, 18 Dec 2016 16:21:13 +0000 (19:21 +0300)]
Minor, more explicit names

9 years agoDon't carry source ids along with sources
Aleksey Kladov [Sun, 18 Dec 2016 15:42:05 +0000 (18:42 +0300)]
Don't carry source ids along with sources

9 years agoBe more explicit about temporary workspaces
Aleksey Kladov [Sat, 17 Dec 2016 09:37:38 +0000 (12:37 +0300)]
Be more explicit about temporary workspaces

9 years agoAdd source_id method to the Source
Aleksey Kladov [Sat, 17 Dec 2016 09:07:37 +0000 (12:07 +0300)]
Add source_id method to the Source

9 years agoAdd a test for `--message-format` parsing the mixed output of rustc
fmdkdd [Fri, 16 Dec 2016 13:16:37 +0000 (14:16 +0100)]
Add a test for `--message-format` parsing the mixed output of rustc

9 years agoRename resolve_dependencies -> resolve_ws_precisely
Aleksey Kladov [Fri, 16 Dec 2016 08:17:02 +0000 (11:17 +0300)]
Rename resolve_dependencies -> resolve_ws_precisely

9 years agoSimplify `resolve_ws` API
Aleksey Kladov [Fri, 16 Dec 2016 08:13:07 +0000 (11:13 +0300)]
Simplify `resolve_ws` API

9 years agoMove `resolve_dependencies` into resolve.rs
Aleksey Kladov [Fri, 16 Dec 2016 08:01:01 +0000 (11:01 +0300)]
Move `resolve_dependencies` into resolve.rs

9 years agoAuto merge of #3411 - alexcrichton:tweaks, r=alexcrichton
bors [Fri, 16 Dec 2016 00:28:35 +0000 (00:28 +0000)]
Auto merge of #3411 - alexcrichton:tweaks, r=alexcrichton

Minor build tweaks

* Clean out OpenSSL when building
* Test 32-bit Cargo on OSX, not the 64-bit version on the 32-bit builder

9 years agoMinor build tweaks
Alex Crichton [Thu, 15 Dec 2016 16:59:51 +0000 (08:59 -0800)]
Minor build tweaks

* Clean out OpenSSL when building
* Test 32-bit Cargo on OSX, not the 64-bit version on the 32-bit builder

9 years agoFix `--message-format JSON` when rustc emits non-JSON warnings
fmdkdd [Thu, 15 Dec 2016 23:05:58 +0000 (00:05 +0100)]
Fix `--message-format JSON` when rustc emits non-JSON warnings

The `--message-format JSON` flag parses all the stderr output of rustc to JSON,
but rustc can emit non-JSON lines to stderr (e.g., for warning about the
unstable `-Z` flag on the stable channel), causing cargo to fail reporting
compilation errors when using `--message-format JSON`.

This commit adds a check to look for lines beginning with `{` to only parse
these lines as JSON.  Other lines from rustc are forwarded to the stderr of
cargo.

Fixes #3390.

9 years agoAuto merge of #3409 - matklad:workspace-manifest-error, r=alexcrichton
bors [Thu, 15 Dec 2016 19:04:28 +0000 (19:04 +0000)]
Auto merge of #3409 - matklad:workspace-manifest-error, r=alexcrichton

Don't ignore errors in workspace manifest

Closes #3407

If we find `Cargo.toml` during an up tree traversal, we'd better not to ignore errors within it!

9 years agoDon't ignore errors in workspace manifest
Aleksey Kladov [Thu, 15 Dec 2016 17:27:48 +0000 (20:27 +0300)]
Don't ignore errors in workspace manifest

9 years agoAuto merge of #3393 - alexcrichton:fix-libz-linkage, r=brson
bors [Thu, 15 Dec 2016 03:04:20 +0000 (03:04 +0000)]
Auto merge of #3393 - alexcrichton:fix-libz-linkage, r=brson

Bump libz-sys to 1.0.9

This just switches libz to always link statically instead of relying on the
system zlib. For MinGW it seems that linkage may default pull in a DLL, which is
almost never what we want.

Closes #3384

9 years agoAuto merge of #3403 - matklad:doc-loc, r=alexcrichton
bors [Thu, 15 Dec 2016 01:28:15 +0000 (01:28 +0000)]
Auto merge of #3403 - matklad:doc-loc, r=alexcrichton

cargo doc: show where are docs

Let's print the file we are trying to open. It's useful when we fail to detect the browser, because the user would be able to copy-paste url manually.

9 years agoBump libz-sys to 1.0.9
Alex Crichton [Tue, 13 Dec 2016 08:22:00 +0000 (00:22 -0800)]
Bump libz-sys to 1.0.9

This just switches libz to always link statically instead of relying on the
system zlib. For MinGW it seems that linkage may default pull in a DLL, which is
almost never what we want.

Also update curl-sys to fix a build issue on MinGW.

Closes #3384

9 years agoAuto merge of #3402 - matklad:packages, r=alexcrichton
bors [Wed, 14 Dec 2016 23:09:13 +0000 (23:09 +0000)]
Auto merge of #3402 - matklad:packages, r=alexcrichton

Refactor packages specification

A small refactoring to avoid returning a triple.

9 years agocargo doc: show where are docs
Aleksey Kladov [Wed, 14 Dec 2016 22:41:31 +0000 (01:41 +0300)]
cargo doc: show where are docs

9 years agoRefactor packages specification
Aleksey Kladov [Wed, 14 Dec 2016 22:12:21 +0000 (01:12 +0300)]
Refactor packages specification

9 years agoAuto merge of #3396 - pornel:test, r=alexcrichton
bors [Wed, 14 Dec 2016 08:52:55 +0000 (08:52 +0000)]
Auto merge of #3396 - pornel:test, r=alexcrichton

Test for issue #2064

I've tried to reproduce the problem from #2064, but to my surprise the test passes reliably :)

9 years agoAuto merge of #3296 - nrc:check, r=alexcrichton
bors [Wed, 14 Dec 2016 07:44:02 +0000 (07:44 +0000)]
Auto merge of #3296 - nrc:check, r=alexcrichton

cargo check

~~This is not finished - the big omission is no tests, and it needs some more testing too. It also requires https://github.com/rust-lang/rust/pull/37681.~~

However, this is my first non-trivial Cargo patch, so I'd like to get some early feedback.

r? @alexcrichton

and cc @rust-lang/tools since this adds a new Cargo sub-command (although we have previously discussed and approved the idea in a tools meeting).

9 years agoAuto merge of #3398 - alexcrichton:git-rev, r=alexcrichton
bors [Wed, 14 Dec 2016 05:56:37 +0000 (05:56 +0000)]
Auto merge of #3398 - alexcrichton:git-rev, r=alexcrichton

Fix git rev showing up in version number

Makefiles didn't support an out-of-tree build, so needed to update them to do
so.

9 years agoAuto merge of #3363 - alexcrichton:libcmt, r=alexcrichton
bors [Wed, 14 Dec 2016 03:38:52 +0000 (03:38 +0000)]
Auto merge of #3363 - alexcrichton:libcmt, r=alexcrichton

Compile statically against the MSVC CRT

This updates our AppVeyor builds to compile with `-Ctarget-feature=+crt-static`
to help Cargo be a bit more portable and not rely on the MSVC redistributable
artifacts. Over time this may even let us converge on only releasing one build
of Cargo and just pairing that with all Windows toolchains...

9 years agoAuto merge of #3399 - alexcrichton:fix-nightly, r=alexcrichton
bors [Wed, 14 Dec 2016 02:30:46 +0000 (02:30 +0000)]
Auto merge of #3399 - alexcrichton:fix-nightly, r=alexcrichton

Fix compatibility with Rust nightly

These two tests actually shouldn't have ever passed, but nightly Rust is more
principled about "$OUT_DIR" and doesn't leak it where possible, so these two
tests were accidentally compiling due to leaking '$OUT_DIR' for Cargo itself.

9 years agoAuto merge of #3386 - matklad:warn-replace, r=alexcrichton
bors [Wed, 14 Dec 2016 01:19:37 +0000 (01:19 +0000)]
Auto merge of #3386 - matklad:warn-replace, r=alexcrichton

Warn if replace is not actually used

closes #3324

I've added warnings to `resolve_dependencies` inside `cargo_compile.rs`. Adding them to `resolve_with_previous` does not work because that method is called several times.

Perhaps the best idea is to refactor resolve facade, such that we have only `ops::resolve`  and not `ops::resolve_ws`, `ops::resolve_with_previous` and `ops::resolve_dependencies`. IIRC, there were some bugs because of logic mismatch between `compile` and `metadata` commands.

9 years agoFix compatibility with Rust nightly
Alex Crichton [Wed, 14 Dec 2016 01:18:32 +0000 (17:18 -0800)]
Fix compatibility with Rust nightly

These two tests actually shouldn't have ever passed, but nightly Rust is more
principled about "$OUT_DIR" and doesn't leak it where possible, so these two
tests were accidentally compiling due to leaking '$OUT_DIR' for Cargo itself.

9 years agoFix git rev showing up in version number
Alex Crichton [Wed, 14 Dec 2016 00:36:31 +0000 (16:36 -0800)]
Fix git rev showing up in version number

Makefiles didn't support an out-of-tree build, so needed to update them to do
so.

9 years agoAuto merge of #3385 - matklad:package-test, r=alexcrichton
bors [Tue, 13 Dec 2016 23:19:55 +0000 (23:19 +0000)]
Auto merge of #3385 - matklad:package-test, r=alexcrichton

Add test for --package and virtual manifest

closes #3194

The issue was actually fixed by #3221 (thanks @euclio !), so let's just add a test (a copy of `virtual_works` basically).

9 years agoAuto merge of #3371 - trafficland:master, r=alexcrichton
bors [Tue, 13 Dec 2016 21:46:34 +0000 (21:46 +0000)]
Auto merge of #3371 - trafficland:master, r=alexcrichton

Add -vv to the list of options printed by cargo --help.

9 years agoCompile statically against the MSVC CRT
Alex Crichton [Fri, 2 Dec 2016 22:34:18 +0000 (14:34 -0800)]
Compile statically against the MSVC CRT

This updates our AppVeyor builds to compile with `-Ctarget-feature=+crt-static`
to help Cargo be a bit more portable and not rely on the MSVC redistributable
artifacts. Over time this may even let us converge on only releasing one build
of Cargo and just pairing that with all Windows toolchains...

9 years agoTest for issue #2064
Kornel Lesiński [Tue, 13 Dec 2016 21:00:15 +0000 (21:00 +0000)]
Test for issue #2064

9 years agoAuto merge of #3395 - alexcrichton:fix-appveyor, r=alexcrichton
bors [Tue, 13 Dec 2016 18:55:46 +0000 (18:55 +0000)]
Auto merge of #3395 - alexcrichton:fix-appveyor, r=alexcrichton

Pin to an older version of rustup temporarily

cc #3394

9 years agoPin to an older version of rustup temporarily
Alex Crichton [Tue, 13 Dec 2016 18:49:45 +0000 (10:49 -0800)]
Pin to an older version of rustup temporarily

cc #3394

9 years agoFix some rebasing errors
Nick Cameron [Tue, 13 Dec 2016 06:33:05 +0000 (20:33 -1000)]
Fix some rebasing errors

9 years agoAuto merge of #3392 - matklad:patch-1, r=steveklabnik
bors [Mon, 12 Dec 2016 19:24:38 +0000 (19:24 +0000)]
Auto merge of #3392 - matklad:patch-1, r=steveklabnik

Add explanatory comment to header.html

See #3387

9 years agoAdd explanatory comment to header.html
Aleksey Kladov [Mon, 12 Dec 2016 18:28:25 +0000 (21:28 +0300)]
Add explanatory comment to header.html

See #3387

9 years agoWarn if replace is not actually used
Aleksey Kladov [Mon, 12 Dec 2016 14:33:12 +0000 (17:33 +0300)]
Warn if replace is not actually used

closes #3324

9 years agoAdd test for --package and virtual manifest
Aleksey Kladov [Mon, 12 Dec 2016 12:57:19 +0000 (15:57 +0300)]
Add test for --package and virtual manifest

closes #3194

9 years agoAdded -vv to the list of options printed by cargo and its sub commands.
Eric D. Reichert [Mon, 5 Dec 2016 14:09:41 +0000 (09:09 -0500)]
Added -vv to the list of options printed by cargo and its sub commands.

9 years agoBe a bit more careful not to crash if the compiler doesn't support --crate-type metadata
Nick Cameron [Thu, 1 Dec 2016 22:25:55 +0000 (11:25 +1300)]
Be a bit more careful not to crash if the compiler doesn't support --crate-type metadata

9 years agotests
Nick Cameron [Tue, 29 Nov 2016 03:10:00 +0000 (16:10 +1300)]
tests

9 years agocargo check
Nick Cameron [Wed, 16 Nov 2016 01:46:24 +0000 (14:46 +1300)]
cargo check

Adds a new mode - check - which only checks code, rather than generating machine code. It takes into account that proc macros and build scripts will still require generated code.

Implemented by adding a check profile and setting this on each Unit, unless the unit is required to be built (i.e., is a proc macro, build script, or dep of one).

9 years agoAuto merge of #3221 - euclio:test-all, r=alexcrichton
bors [Thu, 8 Dec 2016 23:55:15 +0000 (23:55 +0000)]
Auto merge of #3221 - euclio:test-all, r=alexcrichton

Add `--all` flag to `cargo test`

Work towards #2878.

This flag allows a user to test all members of a workspace by using `cargo test --all`. The command is also supported when using a virtual workspace manifest.

9 years agoreplace `current_opt` with membership check
Andy Russell [Thu, 8 Dec 2016 22:32:33 +0000 (17:32 -0500)]
replace `current_opt` with membership check

9 years agofix formatting issues
Andy Russell [Fri, 2 Dec 2016 21:03:42 +0000 (16:03 -0500)]
fix formatting issues

9 years agoremove unused argument to `Context::lib_profile`
Andy Russell [Fri, 2 Dec 2016 20:28:40 +0000 (15:28 -0500)]
remove unused argument to `Context::lib_profile`

9 years agoremove unnecessary usage of `current_opt`
Andy Russell [Fri, 2 Dec 2016 20:21:31 +0000 (15:21 -0500)]
remove unnecessary usage of `current_opt`

9 years agoavoid round-tripping through string
Andy Russell [Fri, 2 Dec 2016 19:40:37 +0000 (14:40 -0500)]
avoid round-tripping through string

9 years agoremove unnecessary match
Andy Russell [Fri, 2 Dec 2016 19:30:16 +0000 (14:30 -0500)]
remove unnecessary match

9 years agoshow warnings for all members of the workspace
Andy Russell [Wed, 16 Nov 2016 21:04:31 +0000 (16:04 -0500)]
show warnings for all members of the workspace

9 years agopass `Packages` into resolve dependencies
Andy Russell [Wed, 16 Nov 2016 20:26:18 +0000 (15:26 -0500)]
pass `Packages` into resolve dependencies

9 years agoremove current_package from context
Andy Russell [Wed, 16 Nov 2016 19:31:06 +0000 (14:31 -0500)]
remove current_package from context

9 years agoadd `--all` flag to `cargo-test`
Andy Russell [Thu, 20 Oct 2016 20:14:54 +0000 (16:14 -0400)]
add `--all` flag to `cargo-test`

9 years agoavoid panic when virtual workspace has no members
Andy Russell [Fri, 21 Oct 2016 03:57:51 +0000 (23:57 -0400)]
avoid panic when virtual workspace has no members

9 years agoAuto merge of #3361 - pwoolcoc:default-build-script, r=alexcrichton
bors [Wed, 7 Dec 2016 08:11:16 +0000 (08:11 +0000)]
Auto merge of #3361 - pwoolcoc:default-build-script, r=alexcrichton

Assume `build.rs` in the same directory as `Cargo.toml` is a build script (unless explicitly told not to)

So, in May I posted a question in the #cargo IRC room: https://botbot.me/mozilla/cargo/2016-05-26/?msg=66770068&page=1

This PR does what was discussed there. If `cargo` sees a `build.rs` in the same directory as the `Cargo.toml`, it will assume `build.rs` is a build script unless `package.build = false`. Just for completeness I also made `build = true` mean the same as `build = "build.rs"` but I'm not sure if that is okay or not.

9 years agochange this to only emit a warning right now
Paul Woolcock [Tue, 6 Dec 2016 15:07:52 +0000 (10:07 -0500)]
change this to only emit a warning right now

9 years agoAuto merge of #3372 - alexcrichton:sha256, r=alexcrichton
bors [Tue, 6 Dec 2016 06:59:46 +0000 (06:59 +0000)]
Auto merge of #3372 - alexcrichton:sha256, r=alexcrichton

Upload sha256 sums of cargo artifacts

9 years agoUpload sha256 sums of cargo artifacts
Alex Crichton [Tue, 6 Dec 2016 06:54:11 +0000 (22:54 -0800)]
Upload sha256 sums of cargo artifacts

9 years agoAuto merge of #3319 - alexcrichton:more-info, r=brson
bors [Tue, 6 Dec 2016 01:23:17 +0000 (01:23 +0000)]
Auto merge of #3319 - alexcrichton:more-info, r=brson

Emit more info on --message-format=json

This adds more output on Cargo's behalf to the output of
`--message-format=json`. Cargo will now emit a message when a crate is finished
compiling with a list of all files that were just generated along with a message
when a build script finishes executing with linked libraries and linked library
paths.

Closes #3212

9 years agocorrect typo
Paul Woolcock [Mon, 5 Dec 2016 18:02:13 +0000 (13:02 -0500)]
correct typo

9 years agoUsing layout.root here should be sufficient
Paul Woolcock [Mon, 5 Dec 2016 14:41:03 +0000 (09:41 -0500)]
Using layout.root here should be sufficient

9 years agoAdded .idea to the list of git exlusions.
Eric D. Reichert [Mon, 5 Dec 2016 14:05:33 +0000 (09:05 -0500)]
Added .idea to the list of git exlusions.

9 years agoAuto merge of #3356 - ibabushkin:feature-build-rustflags, r=alexcrichton
bors [Fri, 2 Dec 2016 23:39:49 +0000 (23:39 +0000)]
Auto merge of #3356 - ibabushkin:feature-build-rustflags, r=alexcrichton

Implemented string lookup for `build.rustflags` config key

This addresses the immediate issue described in #3052 .
I am, however, unsure about the current state of the deeper issues mentioned in that issue, but if needed, I can take stab at them as well. :)

9 years agoAuto merge of #3362 - alexcrichton:slower-ssl, r=alexcrichton
bors [Fri, 2 Dec 2016 22:33:17 +0000 (22:33 +0000)]
Auto merge of #3362 - alexcrichton:slower-ssl, r=alexcrichton

Use -j1 on recursive make for OpenSSL

It looks like OpenSSL building on OSX has races...

9 years agoUse -j1 on recursive make for OpenSSL
Alex Crichton [Fri, 2 Dec 2016 22:27:37 +0000 (14:27 -0800)]
Use -j1 on recursive make for OpenSSL

It looks like OpenSSL building on OSX has races...

9 years agoTests for new `package.build` behavior
Paul Woolcock [Fri, 2 Dec 2016 04:01:51 +0000 (23:01 -0500)]
Tests for new `package.build` behavior

9 years agoAssume build = 'build.rs' by default
Paul Woolcock [Fri, 2 Dec 2016 03:42:45 +0000 (22:42 -0500)]
Assume build = 'build.rs' by default

This change makes cargo assume `build = "build.rs"` if there is a
`build.rs` file in the same directory as `Cargo.toml`. However, you
can set `build = false` to prevent this.

9 years agoRefactored ugly rustflags lookup code into a separate function.
Inokentiy Babushkin [Fri, 2 Dec 2016 18:43:37 +0000 (19:43 +0100)]
Refactored ugly rustflags lookup code into a separate function.

9 years agoEmit more info on --message-format=json
Alex Crichton [Wed, 23 Nov 2016 16:29:36 +0000 (08:29 -0800)]
Emit more info on --message-format=json

This adds more output on Cargo's behalf to the output of
`--message-format=json`. Cargo will now emit a message when a crate is finished
compiling with a list of all files that were just generated along with a message
when a build script finishes executing with linked libraries and linked library
paths.

Closes #3212

9 years agoAuto merge of #3358 - tshepang:formatting, r=alexcrichton
bors [Fri, 2 Dec 2016 17:31:04 +0000 (17:31 +0000)]
Auto merge of #3358 - tshepang:formatting, r=alexcrichton

doc: fix code formatting

9 years agoFixed broken testcase for string-based form of rustflags config key.
Inokentiy Babushkin [Fri, 2 Dec 2016 15:00:58 +0000 (16:00 +0100)]
Fixed broken testcase for string-based form of rustflags config key.

9 years agoAuto merge of #3348 - alexcrichton:fix-checksums, r=brson
bors [Fri, 2 Dec 2016 14:37:52 +0000 (14:37 +0000)]
Auto merge of #3348 - alexcrichton:fix-checksums, r=brson

Fix retrying crate downloads for network errors

Previously the `with_retry` loop was a little too tight where stale state about
the sha256 and data was kept out of the loop. Instead we need to reinitialize
these on each iteration of the loop to ensure that we correctly retry by
forgetting the data we previously downloaded for an aborted download attempt.

9 years agoAuto merge of #3338 - alexcrichton:correct-vers-flag, r=brson
bors [Fri, 2 Dec 2016 13:23:38 +0000 (13:23 +0000)]
Auto merge of #3338 - alexcrichton:correct-vers-flag, r=brson

Require `cargo install --vers` takes a semver version

Historically Cargo accidentally took a semver version *requirement*, so let's
start issuing warnings about how this is now legacy behavior.

Closes #3321

9 years agoAuto merge of #3335 - alexcrichton:fix-xcomiple, r=brson
bors [Fri, 2 Dec 2016 12:15:18 +0000 (12:15 +0000)]
Auto merge of #3335 - alexcrichton:fix-xcomiple, r=brson

Add host dependency path via -L for cross compiles

Now that proc-macro crates can reexport from their dependencies we need to be
able to find the other crates, so ensure that we pass an appropriate -L flag.

Closes #3334

9 years agoAdd host dependency path via -L for cross compiles
Alex Crichton [Mon, 28 Nov 2016 15:27:14 +0000 (07:27 -0800)]
Add host dependency path via -L for cross compiles

Now that proc-macro crates can reexport from their dependencies we need to be
able to find the other crates, so ensure that we pass an appropriate -L flag.

Closes #3334

9 years agoAuto merge of #3336 - alexcrichton:fix-warning, r=brson
bors [Fri, 2 Dec 2016 03:20:54 +0000 (03:20 +0000)]
Auto merge of #3336 - alexcrichton:fix-warning, r=brson

Test for bad path overrides with summaries

Bad path overrides are currently detected to issue warnings in cases where path
overrides are not suitable and have exhibited buggy behavior in the past.
Unfortunately though it looks like some false positives are being issued,
causing unnecessary confusion about `paths` overrides.

This commit fixes the detection of these "bad path overrides" by comparing
`Summary` dependencies (what's written down in `Cargo.toml`) rather than
comparing the `Cargo.toml` of the override with `Cargo.lock`. We're guaranteed
that the package we're overridding has already been resolved into `Cargo.lock`,
so we know that if the two `Cargo.toml` files are equivalent we'll continue
with the same crate graph.

I'm not actually entirely sure why I originally thought it'd be better to go
through the `Cargo.lock` comparison route. Unfortunately that doesn't take into
account optional deps which aren't in `Cargo.lock` but are in `Cargo.toml` of
the override, causing the false positive. This method, however, simply ensures
that the two dependency lists are the same.

Closes #3313

9 years agodoc: fix code formatting
Tshepang Lekhonkhobe [Thu, 1 Dec 2016 20:08:59 +0000 (22:08 +0200)]
doc: fix code formatting

9 years agoAuto merge of #3310 - alexcrichton:more-metadata-hashing, r=brson
bors [Fri, 2 Dec 2016 00:05:12 +0000 (00:05 +0000)]
Auto merge of #3310 - alexcrichton:more-metadata-hashing, r=brson

Apply new fingerprinting to build dir outputs

We now much more aggressively cache the output of the compiler based on feature
sets and profile configuration. Unfortunately we forgot to extend this caching
to build script output directories as well so this commit ensures that build
script outputs are cached the same way with a directory per configuration of
features and output settings.

Closes #3302

9 years agoImproved error handling to reflect the actual situation, added tests
Inokentiy Babushkin [Thu, 1 Dec 2016 23:03:49 +0000 (00:03 +0100)]
Improved error handling to reflect the actual situation, added tests

* One of the tests still doesn't pass, this needs further investigation

9 years agoAuto merge of #3357 - tshepang:no-exist, r=steveklabnik
bors [Thu, 1 Dec 2016 22:10:06 +0000 (22:10 +0000)]
Auto merge of #3357 - tshepang:no-exist, r=steveklabnik

doc: remove reference to non-existent function

9 years agoAuto merge of #3354 - alexcrichton:less-snapshots, r=alexcrichton
bors [Thu, 1 Dec 2016 20:12:40 +0000 (20:12 +0000)]
Auto merge of #3354 - alexcrichton:less-snapshots, r=alexcrichton

Delete old snapshot infrastructure

No longer used

9 years agodoc: remove reference to non-existent function
Tshepang Lekhonkhobe [Thu, 1 Dec 2016 19:59:03 +0000 (21:59 +0200)]
doc: remove reference to non-existent function

9 years agoAuto merge of #3355 - alexcrichton:change-buckets, r=alexcrichton
bors [Thu, 1 Dec 2016 19:01:17 +0000 (19:01 +0000)]
Auto merge of #3355 - alexcrichton:change-buckets, r=alexcrichton

Upload to a different bucket

9 years agoImplemented string lookup for `build.rustflags` config key
Inokentiy Babushkin [Thu, 1 Dec 2016 18:57:05 +0000 (19:57 +0100)]
Implemented string lookup for `build.rustflags` config key

9 years agoUpload to a different bucket
Alex Crichton [Thu, 1 Dec 2016 18:23:48 +0000 (10:23 -0800)]
Upload to a different bucket

9 years agoDelete old snapshot infrastructure
Alex Crichton [Thu, 1 Dec 2016 17:18:47 +0000 (09:18 -0800)]
Delete old snapshot infrastructure

No longer used

9 years agoAuto merge of #3350 - alexcrichton:more-tweaks, r=alexcrichton
bors [Thu, 1 Dec 2016 07:49:11 +0000 (07:49 +0000)]
Auto merge of #3350 - alexcrichton:more-tweaks, r=alexcrichton

Slight tweaks to CI

* Pass `--quiet` to all tests to have some quieter output
* Skip builds on the `master` branch as `auto` is already checked
* Check the right env var for repo branches on appveyor